import request from '@/utils/request'


var myurl = '/system/patient';
// 查询门诊类型
/*export function listdept() {
  return request({
    url: myurl+'/listDepts',
    method: 'get',
  })
}*/

export function listdept(query) {
  return request({
    url: myurl+'/listDepts',
    method: 'get',
    params: query
  });
}

//添加患者
export function addPatient(data) {
  return request({
    url: myurl+'/addPatient',
    method: 'post',
    params: data
  });
}


//用户信息回显
export function findPatient(registerId) {
  return request({
    url: myurl+'/findPatient',
    method: 'get',
    params: {registerId}
  })
}

//修改当前人数
export function updatePeople(deptId,beforeCode) {
  return request({
    url: myurl+'/updatePeople',
    method: 'get',
    params: {deptId:deptId,beforecode:beforeCode}
  })
}

//查询挂号费
export function queryRegis(regisId,patientId) {
  return request({
    url: myurl+'/queryRegis',
    method: 'get',
    params: {regisId,patientId}
  })

}

//添加患者的科室id
export function addDept(patientId,deptId,beforeCode) {
  return request({
    url: myurl+'/addDept',
    method: 'get',
    params: {patientId: patientId,deptId :deptId,beforeCode:beforeCode}
  })
}
